package ar.com.larreta.persistencia;

import org.hibernate.criterion.Restrictions;
import org.hibernate.criterion.SimpleExpression;

import com.extjs.gxt.ui.client.data.BaseBooleanFilterConfig;
import com.extjs.gxt.ui.client.data.BaseFilterConfig;

public class AdaptadorBaseBooleanFilterConfig implements AdaptadorFiltros{

	public SimpleExpression obtenerRestriccion(BaseFilterConfig filterConfig) {
		BaseBooleanFilterConfig booleanFilterConfig = (BaseBooleanFilterConfig) filterConfig;
		return Restrictions.eq(filterConfig.getField(), filterConfig.getValue());
	}

}
